import request from '@/utils/request'
import type { SaleType, SaleResult } from './types'

class APIMarket {
    /** 销售广场-未登录  */
    static getSale(type: SaleType, params?: PageQuery) {
        return request<SaleResult[]>('/getSale', {
            method: 'POST',
            body: { type },
            params
        })
    }
    /** 销售广场-已登录 */
    static getLoginSale(type: SaleType, params?: PageQuery) {
        return request<SaleResult[]>('/getLoginSale', {
            method: 'POST',
            body: { type },
            params
        })
    }

}

export default APIMarket
